#include <stdio.h>

int main(){
    int n;
    printf("Enter a number: ");
    scanf("%d",&n);
    int a=2,b=1;
    int i,temp;
    double sum;
    for(i=0;i<n;i++){
        sum+=(double)a/b;
        temp=a;
        a+=b;
        b=temp;
    }
    printf("%lf\n",sum);
    return 0;
}
